<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <div class="bg"></div>
    
</body>

<style>
    .bg{
        width: 400px;
        height: 200px;
        background: linear-gradient(
            140deg,
            rgb(23, 147, 219),
            rgb(109, 224, 119),
            rgb(180, 48, 99),
            rgb(23, 147, 219),
            rgb(109, 182, 224),
            rgb(23, 147, 219)
        );
        background-size: 200% 200%;
        animation: bgMove 3s;
        animation-fill-mode: forwards;
        animation-direction: alternate;
        animation-iteration-count: infinite;
    }
    @keyframes bgMove {
        0%{
            background-position: 0% 0%;
        }
        100%{
            background-position: 100% 100%;
        }
    }
</style>
</html>